/**
 * Created with IntelliJ IDEA.
 * Description:
 */
public class TestDemo {
    public static void main(String[] args) {
        int[] array = {1,2,3};
        int[] array1 = transform(array);
        for (int i = 0; i < 3; i++) {
            System.out.print(array1[i]+" ");
        }
    }

    public static int[] transform(int[] array){
        int[] arr = new int[array.length];
        for (int i = 0; i < 3; i++) {
            arr[i] = array[i]*2;
        }
        return arr;
    }
}
